org.eclipse.vtp.framework.interactions.voice.vxml
Class Submit

java.lang.Object
  extended by org.eclipse.vtp.framework.interactions.core.support.Widget
      extended by org.eclipse.vtp.framework.interactions.voice.vxml.Action
          extended by org.eclipse.vtp.framework.interactions.voice.vxml.Goto
              extended by org.eclipse.vtp.framework.interactions.voice.vxml.Submit
All Implemented Interfaces:
VXMLConstants

public class Submit
extends Goto

The Submit class represents the <submit> VXML element. This element acts exactly like the goto element, except that data can be passed to the next document as well.

Version:
2.0
Author:
Trip Gilman, Lonnie Pryor

Field Summary
 
Fields inherited from interface org.eclipse.vtp.framework.interactions.voice.vxml.VXMLConstants
EMPTY, FILE_EXT_GSL, FILLED_MODE_ALL, FILLED_MODE_ANY, GRAMMAR_MODE_DTMF, GRAMMAR_MODE_VOICE, METHOD_GET, METHOD_POST, MIME_TYPE_GSL, MIME_TYPE_SRGS, NAME_APPLICATION, NAME_ASSIGN, NAME_AUDIO, NAME_BARGEIN, NAME_BEEP, NAME_BLOCK, NAME_BRIDGE, NAME_CATCH, NAME_CHOICE, NAME_COMPLETETIMEOUT, NAME_COND, NAME_CONFIDENCELEVEL, NAME_COUNT, NAME_DEST, NAME_DISCONNECT, NAME_DTMF, NAME_DTMFTERM, NAME_ELSE, NAME_ELSEIF, NAME_ENCTYPE, NAME_ENUMERATE, NAME_ERROR, NAME_EVENT, NAME_EVENTEXPR, NAME_EXIT, NAME_EXPR, NAME_FIELD, NAME_FILLED, NAME_FINALSILENCE, NAME_FORM, NAME_GOTO, NAME_GRAMMAR, NAME_ID, NAME_IF, NAME_INCOMPLETETIMEOUT, NAME_INPUTMODES, NAME_INTERDIGITTIMEOUT, NAME_ITEM, NAME_MAXNBEST, NAME_MAXSPEECHTIMEOUT, NAME_MAXTIME, NAME_MENU, NAME_METHOD, NAME_MODE, NAME_NAME, NAME_NAMELIST, NAME_NEXT, NAME_NOINPUT, NAME_NOMATCH, NAME_ONE_OF, NAME_OPTION, NAME_PARAM, NAME_PROMPT, NAME_PROPERTY, NAME_RECORD, NAME_REPEAT, NAME_REPROMPT, NAME_RETURN, NAME_ROOT, NAME_RULE, NAME_SCOPE, NAME_SCRIPT, NAME_SENSITIVITY, NAME_SPEEDVSACCURACY, NAME_SRC, NAME_SUBDIALOG, NAME_SUBMIT, NAME_TERMCHAR, NAME_TERMTIMEOUT, NAME_THROW, NAME_TIMEOUT, NAME_TRANSFER, NAME_TYPE, NAME_VALUE, NAME_VAR, NAME_VERSION, NAME_VXML, NAMESPACE_URI_VXML, QNAME_XML_LANG, SCOPE_DIALOG, SCOPE_DOCUMENT, TYPE_CDATA, VERSION_2_0
 
Constructor Summary
Submit(java.lang.String targetURI)
          Creates a new Submit object that will transfer execution to the given URI.
Submit(java.lang.String targetURI, java.lang.String[] names)
          Creates a new Submit object that will transfer execution and pass the specified variable values to the given URI.
 
Method Summary
 void addName(java.lang.String name)
          Adds the variable name to the list of variables to pass to the next document.
 java.lang.String getEncodingType()
          Returns the encoding type for the parameters.
 java.lang.String getMethod()
          Returns the HTTP method to send data with.
 java.lang.String[] getNames()
          Returns the list of variable names to pass to the next document.
 void removeName(java.lang.String name)
          Removes the variable name from the list of variables to pass to the next document.
 void setEncodingType(java.lang.String encodingType)
          Sets the encoding type for the parameters.
 void setMethod(java.lang.String method)
          Sets the HTTP method to send data with.
protected  void writeAttributes(org.xml.sax.helpers.AttributesImpl attributes)
          Write the attribute members of this action to the supplied set.
 void writeWidget(org.xml.sax.ContentHandler outputHandler)
          Writes the content of this widget to an XML content handler.
 
Methods inherited from class org.eclipse.vtp.framework.interactions.voice.vxml.Goto
getTargetURI, setTargetURI
 
Methods inherited from class org.eclipse.vtp.framework.interactions.core.support.Widget
toString, writeAttribute, writeChildren, writeChildren, writeWidget, writeWidget
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Submit

public Submit(java.lang.String targetURI)
Creates a new Submit object that will transfer execution to the given URI.

Parameters:
targetURI - URI of the next document to process.
Throws:
java.lang.IllegalArgumentException - If the supplied URI is empty.
java.lang.NullPointerException - If the supplied URI is null.

Submit

public Submit(java.lang.String targetURI,
              java.lang.String[] names)
Creates a new Submit object that will transfer execution and pass the specified variable values to the given URI.

Parameters:
targetURI - URI of the next document to process.
names - List of variables to pass to the next document.
Throws:
java.lang.IllegalArgumentException - If the supplied URI is empty.
java.lang.IllegalArgumentException - If any of the supplied names are empty.
java.lang.NullPointerException - If the supplied URI is null.
java.lang.NullPointerException - If any of the supplied names are null.
Method Detail

getMethod

public java.lang.String getMethod()
Returns the HTTP method to send data with.

Returns:
The HTTP method to send data with.

getEncodingType

public java.lang.String getEncodingType()
Returns the encoding type for the parameters.

Returns:
The encoding type for the parameters.

getNames

public java.lang.String[] getNames()
Returns the list of variable names to pass to the next document.

Returns:
the list of variable names to pass to the next document.

setMethod

public void setMethod(java.lang.String method)
               throws java.lang.IllegalArgumentException,
                      java.lang.NullPointerException
Sets the HTTP method to send data with.

Parameters:
method - The HTTP method to send data with.
Throws:
java.lang.IllegalArgumentException - If the supplied method is empty.
java.lang.NullPointerException - If the supplied method is null.

setEncodingType

public void setEncodingType(java.lang.String encodingType)
                     throws java.lang.IllegalArgumentException
Sets the encoding type for the parameters.

Parameters:
encodingType - The encoding type for the parameters
Throws:
java.lang.IllegalArgumentException - If the supplied encoding type is empty.

addName

public void addName(java.lang.String name)
Adds the variable name to the list of variables to pass to the next document.

Parameters:
name - The variable name to add.
Throws:
java.lang.IllegalArgumentException - If the supplied name is empty.
java.lang.NullPointerException - If the supplied name is null.

removeName

public void removeName(java.lang.String name)
Removes the variable name from the list of variables to pass to the next document.

Parameters:
name - The variable name to remove.
Throws:
java.lang.IllegalArgumentException - If the supplied name is empty.
java.lang.NullPointerException - If the supplied name is null.

writeWidget

public void writeWidget(org.xml.sax.ContentHandler outputHandler)
                 throws java.lang.NullPointerException,
                        org.xml.sax.SAXException
Description copied from class: Widget
Writes the content of this widget to an XML content handler.

Overrides:
writeWidget in class Goto
Parameters:
outputHandler - The handler to write this widget to.
Throws:
java.lang.NullPointerException - If the supplied content handler is null.
org.xml.sax.SAXException - If the writing of this widget fails.

writeAttributes

protected void writeAttributes(org.xml.sax.helpers.AttributesImpl attributes)
Description copied from class: Goto
Write the attribute members of this action to the supplied set.

Overrides:
writeAttributes in class Goto
Parameters:
attributes - The attribute set to write to.